home *** CD-ROM | disk | FTP | other *** search
/ Info-Mac 4 / Info_Mac IV CD-ROM (Pacific HiTech Inc.)(August 1994).iso / Development / General / ViewIt™ 2.24 Shareware / C Demo Projects / THINK C 6.0 Demos / FaceStorLC.h < prev    next >
Text File  |  1994-01-27  |  6KB  |  272 lines

  1. /* FaceWare 2.23 Commands & Shared Record */
  2. /* ©FaceWare 1989-94. All Rights Reserved. */
  3.  
  4. #define    DoInit       -61L
  5. #define    DoPrep    -62L
  6. /* FaceIt commands */
  7. #define    DoLoop         0L
  8. #define    DoEvnt    -51L
  9. #define    DoMenu    -52L
  10. #define    GetMsg    -55L
  11. /* ViewIt commands */
  12. #define    DoUpdt2   -53L
  13. #define    DoUpdt    -53L
  14. #define    DoUnld    -63L
  15. #define    ChgCur    121L
  16. #define    PstEvt    122L
  17. #define    PopMen    123L
  18. #define    PstNot    124L
  19. #define    SetIdl    131L
  20. #define    EndIdl    132L
  21. #define    ShoAlt    153L
  22. #define    StpAlt    154L
  23. #define    NotAlt    155L
  24. #define    CtnAlt    156L
  25. #define    SetItm1   160L
  26. #define    SetItm2   161L
  27. #define    SetItm    161L
  28. #define    GetItm    162L
  29. #define    FixFSC    163L
  30. #define    SelFSC    164L
  31. #define    ChkMem    171L
  32. #define    NewBlk    172L
  33. #define    PrgCmd    173L
  34. #define    GetFgC    178L
  35. #define    GetBkC    179L
  36. #define    SetFgC    180L
  37. #define    SetBkC    181L
  38. #define    SetFSS    183L
  39. #define    SetPal2   185L
  40. #define    SetPal    185L
  41. #define    StdOpn    201L
  42. #define    StdSav    202L
  43. #define    GetRef    205L
  44. #define    SetRef    206L
  45. #define    SetTyp    208L
  46. #define    SndBhd    250L
  47. #define    GetNam    251L
  48. #define    SetNam    252L
  49. #define    MovRec    254L
  50. #define    MovAlt    255L
  51. #define    MovDlg    256L
  52. #define    MovWin    257L
  53. #define    DrgWnd    259L
  54. #define    ShoStr    261L
  55. #define    StpStr    262L
  56. #define    NotStr    263L
  57. #define    CtnStr    264L
  58. #define    GetStd    301L
  59. #define    SetStd    302L
  60. #define    SavDlg    356L
  61. #define    SavWin    357L
  62. #define    SetSub    451L
  63. #define    TrmStr    452L
  64. #define    SetPrm    453L
  65. #define    CnvStr    454L
  66. #define    FndTxt    455L
  67. #define    NumToS    471L
  68. #define    SToNum    481L
  69. #define    GetStr    491L
  70. #define    SetStr    492L
  71. #define    SrtLst    493L
  72. #define    DupLst    494L
  73. #define    AddVew  -1200L
  74. #define    NewWnd  -1201L
  75. #define    EndWnd  -1202L
  76. #define    MdlWnd  -1203L
  77. #define    SizWnd  -1204L
  78. #define MovWnd  -1205L
  79. #define    ShoWnd  -1206L
  80. #define    HidWnd  -1207L
  81. #define    GetWVC  -1208L
  82. #define    GetWnd  -1209L
  83. #define    LnkCtl  -1210L
  84. #define    GetCtl  -1211L
  85. #define    ShoCtl  -1212L
  86. #define    GetVal  -1213L
  87. #define    SetVal  -1214L
  88. #define    OvrCtl  -1215L
  89. #define    AddCtl  -1216L
  90. #define    DrwCtl  -1217L
  91. #define    ScrCtl  -1218L
  92. #define    ActCtl  -1219L
  93. #define    SelCtl  -1220L
  94. #define    DspCtl  -1221L
  95. #define    StlCtl  -1222L
  96. #define    SavCtl  -1223L
  97. #define    SavWnd  -1224L
  98. #define    SizCtl  -1225L
  99. #define    MovCtl  -1226L
  100. #define    ClrCtl  -1227L
  101. #define    SetVCod -1228L
  102. #define    SetInfo -1228L
  103. #define HlpWnd    -1229L
  104. #define HitCtl    -1230L
  105.  
  106. /* function prototypes */
  107. void PrepIt (long x, long b, long v, long r, long f);
  108. void FaceIt (void* thePtr, long m1, long m2, long m3, long m4, long m5);
  109.  
  110. /* Global FaceWare record */
  111. typedef struct FaceRec {
  112. /* program-wide info */
  113.     short            fHead[8];
  114.     GrafPtr            fOffPort;
  115.     GrafPtr            fCOffPort;
  116.     WindowPtr        fActiveWnd;
  117.     long            fActiveRec;
  118.     short            fActiveID;
  119.     short            fActiveResID;
  120.     short            fMsgCount;
  121.     long            fFlags;
  122.     Ptr                fStuff;
  123.     long            fHeapBuff;
  124.     long            fEnvFlags;
  125.     long            fSleep;
  126.     Rect            fScreenRect;
  127.     Rect            fDragRect;
  128.     long            fFrontSleep;
  129.     long            fBackSleep;
  130.     short            fFiller1;
  131.     Handle            fStdBlock;
  132.     short            fStdCount;
  133.     short            fSysEnvArr[8];
  134.     short            fApplVRef;
  135.     OSType            fCreator;
  136.     long            fRefCon;
  137.     short            fFiller2[7];
  138.     short            fCursor;
  139.     MenuHandle        fFontMenu;
  140.     MenuHandle        fSizeMenu;
  141.     MenuHandle        fStyleMenu;
  142.     MenuHandle        fColorMenu;
  143.     SignedByte        fFiller3;
  144.     SignedByte        fI1Err;
  145.     short            fI2Err;
  146.     long            fI4Err;
  147.     short            fI8Err[4];
  148.     float            fR4Err;
  149.     short            fR8Err[4];
  150.     short            fR10Err[5];
  151.     short            fR12Err[6];
  152.     short            fFiller4[105];
  153.     long            fDrvr7400;
  154.     SignedByte        fMBarHt;
  155.     SignedByte        fDecPtCh;
  156.     short            fSysFNum;
  157.     char            fSysFName[32];
  158.     long            fWDEF;
  159.     long            fGlueData;
  160.     long            fWaitNextEvent;
  161.     long            fGetNewWindow;
  162.     long            fGetNewCWindow;
  163.     long            fDisposeWindow;
  164.     long            fFiller5[4];
  165.     long            fActiveWindow;
  166.     long            fSelectWindow;
  167.     long            fUpdateOther;
  168.     ProcPtr            fFiller6[9];
  169.     EventRecord        fEvent;
  170.     short            fFiller7[190];
  171. /* utility scratch variables */
  172.     FSSpec            uFSSpec;
  173.     short            uHead[8];
  174.     short            uI2;
  175.     long            uI4;
  176.     float            uR4;
  177.     short            uR8[4];
  178.     short            uR10[5];
  179.     short            uR12[6];
  180.     Point            uPt;
  181.     Rect            uRect;
  182.     long            uCommand;
  183.     long            uParam[4];
  184.     long            uResult;
  185.     long            uMenuID;
  186.     long            uMenuItem;
  187.     char            uString[256];
  188.     char            uName[256];
  189.     short            uRGB[3];
  190.     Style            uStyle;
  191.     SignedByte        uI1;
  192.     short            uI8[4];
  193.     MenuHandle        uMenuHdl;
  194. /* window-related info */
  195.     short            vHead[8];
  196.     short            vErr;
  197.     ProcPtr            vCDEF;
  198.     ControlHandle    vSelectCtl;
  199.     long            vSelectRec;
  200.     short            vSelectID;
  201. /* info returned by enabled items */
  202.     short            wiHit;
  203.     short            wvHit;
  204.     short            wcHit;
  205.     short            wClick;
  206.     EventRecord        wEvent;
  207. /* window info returned by GetWnd */
  208.     WindowPtr        wWindow;
  209.     short            wResID;
  210.     short            wCount;
  211.     short            wvCount;
  212.     short            wiCount;
  213. /* control info returned by GetCtl */
  214.     ControlHandle    cControl;
  215.     short            ciIndex;
  216.     short            cvIndex;
  217.     short            ccIndex;
  218.     short            cBaseID;
  219. /* info copied from "cControl" block... */
  220.     ControlHandle    cNext;
  221.     WindowPtr        cOwner;
  222.     Rect            cRect;
  223.     SignedByte        cVis;
  224.     SignedByte        cHilite;
  225.     short            cValue;
  226.     short            cMin;
  227.     short            cMax;
  228.     Handle            cInfo;
  229.     Handle            cLoData;
  230.     ProcPtr            cAction;
  231.     long            cRefCon;
  232.     char            cTitle[256];
  233. /* info copied from "cInfo" block...*/
  234.     short            cStuff[6];
  235.     long            cTmplRefCon;
  236.     Ptr                cPtr;
  237.     Handle            cHiData;
  238.     ControlHandle    cView;
  239.     Rect            cOldRect;
  240.     Rect            cClip;
  241.     Rect            cContent;
  242.     Rect            cLimit;
  243.     long            cType;
  244.     short            cVarCode;
  245.     ResType            cResType;
  246.     short            cResID;
  247.     Handle            cResHdl;
  248.     long            cPrivate;
  249.     unsigned char    cScrInc;
  250.     unsigned char    cCmdKey;
  251.     short            cPnRound;
  252.     Point            cPnSize;
  253.     SignedByte        cTxJust;
  254.     Style            cTxFace;
  255.     short            cTxSize;
  256.     short            cTxFont;
  257.     short            cDataType;
  258.     SignedByte        cDataDigits;
  259.     SignedByte        cDataFormat;
  260.     short            cDataOffset;
  261.     Ptr                cDataPtr;
  262.     short            cStorType;
  263.     long            cStorPtr;
  264.     Handle            cColors;
  265.     ProcPtr            cOverride;
  266.     short            cCount;
  267.     char            cString[256];
  268. /* private debugging table */
  269.     short            xEntries;
  270.     long            xTable[40];
  271. } *FacePtr;
  272.